﻿Jxstar.currentPage = function() {
	var config = {param:{},initpage:function(page, define){},eventcfg:{}};
	
	var auditData = Jxstar.findComboData('audit');
	var planyearData = Jxstar.findComboData('planyear');
	var store_statusData = Jxstar.findComboData('store_status');
	var moneytypeData = Jxstar.findComboData('moneytype');
	var timelinessData = Jxstar.findComboData('timeliness');
	var items = [{
		width:'97%',
		border:false,
		layout:'form',
		autoHeight:true,
		xtype:'container',
		style:'padding:5 10 5 10;',
		items:[{
			anchor:'100%',
			border:false,
			xtype:'container',
			layout:'column',
			autoHeight:true,
			items:[{
				border:false,
				xtype:'container',
				columnWidth:0.495,
				layout:'form',
				style: 'padding-left:10px;',
				items:[
					{xtype:'combo', fieldLabel:'记录状态', name:'project_store__auditing',
						anchor:'100%', readOnly:true, editable:false,
						store: new Ext.data.SimpleStore({
							fields:['value','text'],
							data: auditData
						}),
						emptyText: jx.star.select,
						mode: 'local',
						triggerAction: 'all',
						valueField: 'value',
						displayField: 'text',
						value: auditData[0][0]},
					{xtype:'textfield', fieldLabel:'投资计划名称', name:'project_store__plan_name', allowBlank:false, labelStyle:'color:#0000FF;', labelSeparator:'*', readOnly:true, anchor:'100%', maxLength:100},
					{xtype:'numberfield', decimalPrecision:2, fieldLabel:'预计总投资(万元)', name:'project_store__plan_money', allowBlank:false, labelStyle:'color:#0000FF;', labelSeparator:'*', readOnly:true, anchor:'100%', maxLength:12},
					{xtype:'textfield', fieldLabel:'固定资产编号', name:'project_store__asset_code', readOnly:true, anchor:'100%', maxLength:20},
					{xtype:'numberfield', decimalPrecision:2, fieldLabel:'数量', name:'project_store__plan_num', readOnly:true, anchor:'100%', maxLength:12},
					{xtype:'textfield', fieldLabel:'计量单位', name:'project_store__plan_unit', readOnly:true, anchor:'100%', maxLength:10},
					{xtype:'numberfield', decimalPrecision:2, fieldLabel:'单价(万元)', name:'project_store__plan_price', readOnly:true, anchor:'100%', maxLength:12},
					{xtype:'combo', fieldLabel:'投资年度', name:'project_store__project_year',
						anchor:'100%', readOnly:true, editable:false,
						store: new Ext.data.SimpleStore({
							fields:['value','text'],
							data: planyearData
						}),
						emptyText: jx.star.select,
						mode: 'local',
						triggerAction: 'all',
						valueField: 'value',
						displayField: 'text',
						value: planyearData[0][0]},
					{xtype:'combo', fieldLabel:'项目库存状态', name:'project_store__plan_status', defaultval:'10',
						anchor:'100%', readOnly:true, editable:false,
						store: new Ext.data.SimpleStore({
							fields:['value','text'],
							data: store_statusData
						}),
						emptyText: jx.star.select,
						mode: 'local',
						triggerAction: 'all',
						valueField: 'value',
						displayField: 'text',
						value: store_statusData[0][0]},
					{xtype:'trigger', fieldLabel:'入库申报部门', name:'project_store__dept_name', defaultval:'fun_getDeptName()',
						anchor:'100%', readOnly:true, triggerClass:'x-form-search-trigger',
						maxLength:50, allowBlank:false, labelStyle:'color:#0000FF;', labelSeparator:'*', editable:true,
						onTriggerClick: function() {
							var selcfg = {pageType:'combogrid', nodeId:'sys_dept', layoutPage:'/public/layout/layout_tree.js', sourceField:'', targetField:'', whereSql:"", whereValue:'', whereType:'', isSame:'1', isShowData:'1', isMoreSelect:'0',isReadonly:'1',queryField:'',likeType:'',fieldName:'project_store.dept_name'};
							JxSelect.createSelectWin(selcfg, this, 'node_project_pull_form');
						}},
					{xtype:'datefield', fieldLabel:'提取时间', name:'project_store__out_time', format:'Y-m-d', anchor:'100%'},
					{xtype:'hidden', fieldLabel:'主键', name:'project_store__planstore_id', anchor:'100%'},
					{xtype:'hidden', fieldLabel:'主管部门ID', name:'project_store__done_deptid', anchor:'100%'}
				]
			},{
				border:false,
				xtype:'container',
				columnWidth:0.495,
				layout:'form',
				style: 'padding-left:10px;',
				items:[
					{xtype:'textfield', fieldLabel:'投资计划编号', name:'project_store__plan_code', readOnly:true, anchor:'100%', maxLength:20},
					{xtype:'combo', fieldLabel:'项目类别', name:'project_store__money_type',
						anchor:'100%', readOnly:true, editable:false,
						store: new Ext.data.SimpleStore({
							fields:['value','text'],
							data: moneytypeData
						}),
						emptyText: jx.star.select,
						mode: 'local',
						triggerAction: 'all',
						valueField: 'value',
						displayField: 'text',
						value: moneytypeData[0][0]},
					{xtype:'numberfield', decimalPrecision:2, fieldLabel:'当年预计付款（万元）', name:'project_store__year_money', anchor:'100%', maxLength:12},
					{xtype:'textfield', fieldLabel:'型号规格', name:'project_store__device_size', readOnly:true, anchor:'100%', maxLength:50},
					{xtype:'textfield', fieldLabel:'生产厂家', name:'project_store__create_factory', readOnly:true, anchor:'100%', maxLength:50},
					{xtype:'textfield', fieldLabel:'出厂日期', name:'project_store__create_date', readOnly:true, anchor:'100%', maxLength:50},
					{xtype:'combo', fieldLabel:'项目时效性', name:'project_store__project_time',
						anchor:'100%', readOnly:true, editable:false, allowBlank:false, labelStyle:'color:#0000FF;', labelSeparator:'*',
						store: new Ext.data.SimpleStore({
							fields:['value','text'],
							data: timelinessData
						}),
						emptyText: jx.star.select,
						mode: 'local',
						triggerAction: 'all',
						valueField: 'value',
						displayField: 'text',
						value: timelinessData[0][0]},
					{xtype:'textfield', fieldLabel:'拟选供应商', name:'project_store__provider', readOnly:true, anchor:'100%', maxLength:50},
					{xtype:'datefield', fieldLabel:'入库申报日期', name:'project_store__plan_date', defaultval:'fun_getToday()', format:'Y-m-d', anchor:'100%', readOnly:true},
					{xtype:'numberfield', allowDecimals:false, fieldLabel:'项目重要性排序', name:'project_store__project_order', anchor:'100%', maxLength:12},
					{xtype:'trigger', fieldLabel:'主管部门', name:'project_store__done_deptname',
						anchor:'100%', readOnly:true, triggerClass:'x-form-search-trigger',
						maxLength:50, allowBlank:false, labelStyle:'color:#0000FF;', labelSeparator:'*', editable:true,
						onTriggerClick: function() {
							var selcfg = {pageType:'combogrid', nodeId:'sys_dept', layoutPage:'/public/layout/layout_tree.js', sourceField:'', targetField:'', whereSql:"", whereValue:'', whereType:'', isSame:'1', isShowData:'1', isMoreSelect:'0',isReadonly:'1',queryField:'',likeType:'',fieldName:'project_store.done_deptname'};
							JxSelect.createSelectWin(selcfg, this, 'node_project_pull_form');
						}},
					{xtype:'hidden', fieldLabel:'申报部门ID', name:'project_store__dept_id', defaultval:'fun_getDeptId()', anchor:'100%'}
				]
			}
			]
		},{
			anchor:'100%',
			border:false,
			xtype:'container',
			layout:'column',
			autoHeight:true,
			items:[{
				border:false,
				xtype:'container',
				columnWidth:0.99,
				layout:'form',
				style: 'padding-left:10px;',
				items:[
					{xtype:'textarea', fieldLabel:'项目需求背景', name:'project_store__project_background', readOnly:true, width:'100%', height:96, maxLength:4000},
					{xtype:'textarea', fieldLabel:'建设内容及方案', name:'project_store__plan_desc', readOnly:true, width:'100%', height:72, maxLength:4000},
					{xtype:'textarea', fieldLabel:'必要性、可行性', name:'project_store__project_cause', readOnly:true, width:'100%', height:96, maxLength:4000},
					{xtype:'textarea', fieldLabel:'项目投资估算', name:'project_store__project_estimate', readOnly:true, width:'100%', height:72, maxLength:4000},
					{xtype:'textarea', fieldLabel:'项目建设目标和预期效果', name:'project_store__project_result', readOnly:true, width:'100%', height:72, maxLength:4000},
					{xtype:'textarea', fieldLabel:'备注', name:'project_store__plan_memo', readOnly:true, width:'100%', height:48, maxLength:200}
				]
			}
			]
		}]
	}];
	
	config.param = {
		items: items,
		funid: 'project_pull'
	};

	
	
	
	return new Jxstar.FormNode(config);
}